﻿@model CMSMVC4.Areas.Admin.Models.ContactModels
@using CMSMVC4.MultiResource

<div class="box paint">
    @using (Ajax.BeginForm("EditContact", "Contact", new AjaxOptions() { HttpMethod = "POST", UpdateTargetId = "dialog", OnSuccess = "show()" }))
    {
        <div class="modal" style="position: relative; top: auto; left: auto; margin: 0 auto 20px; z-index: 1; max-width: 100%;">
            <div class="modal-header">
                <button type="button" class="close1" data-dismiss="modal" aria-hidden="true">
                    ×</button>
                <h3 id="myModalLabel">Modal Heading</h3>
            </div>
            <div class="modal-body">
                <div class="form-row control-group row-fluid">
                    <label class="control-label span3">@Admin.Company (*)<span class="help-block">@Admin.CompanyMess</span>
                    </label>
                    <div class="controls span7">
                        <input type="text" value="@ViewBag.Data["Name"].ToString()" class="span12" name="CompanyVi"/>
                        @Html.ValidationMessageFor(x => x.CompanyVi)
                    </div>
                </div>
                <div class="form-row control-group row-fluid">
                    <label class="control-label span3">@Admin.Phone (*)<span class="help-block">@Admin.PhoneMess</span>
                    </label>
                    <div class="controls span7">
                        <input class="span12" type="text" name="Phone" value="@ViewBag.Data["Phone"].ToString()"/>
                        @Html.ValidationMessageFor(x => x.Phone)
                    </div>
                </div>
                <div class="form-row control-group row-fluid">
                    <label class="control-label span3">@Admin.Fax (*)<span class="help-block">@Admin.FaxMess</span>
                    </label>
                    <div class="controls span7">
                        <input class="span12" type="text" name="Fax" value="@ViewBag.Data["Fax"].ToString()"/>
                        @Html.ValidationMessageFor(x => x.Fax)
                    </div>
                </div>
                <div class="form-row control-group row-fluid">
                    <label class="control-label span3">@Admin.Email (*)<span class="help-block">@Admin.EmailMess</span>
                    </label>
                    <div class="controls span7">
                        <input class="span12" type="text" name="Email" value="@ViewBag.Data["Email"].ToString()"/>
                        @Html.ValidationMessageFor(x => x.Email)
                    </div>
                </div>
                <div class="form-row control-group row-fluid">
                    <label class="control-label span3">@Admin.Website (*)<span class="help-block">http://www.envato.com</span></label>
                    <div class="controls span7 ">
                        <input class="span12" type="text" name="Website" value="@ViewBag.Data["Website"].ToString()"/>
                        @Html.ValidationMessageFor(x => x.Website)
                    </div>
                </div>
                <div class="control-group row-fluid">
                    <label class="control-label span3">@Admin.Map <span class="help-block">@Admin.MapMess</span></label>
                    <div class="controls span7">
                        <textarea class="row-fluid" rows="3" name="Map">@ViewBag.Data["Url"]</textarea>
                    </div>
                </div>
                <div class="control-group row-fluid">
                    <label class="control-label span3">@Admin.Address (*)<span class="help-block">@Admin.AddressMess</span></label>
                    <div class="controls span7">
                        <ul id="tabExample1" class="nav nav-tabs">
                            <li class="active"><a href="#addEn" data-toggle="tab" style="color: black">@Admin.English</a></li>
                            <li><a href="#addVi" data-toggle="tab" style="color: black">@Admin.Vietnamese</a></li>
                        </ul>
                        <div class="tab-content">
                            <div class="tab-pane fade in active" id="addEn">
                                <textarea class="row-fluid" rows="3" name="AddressEn">@ViewBag.AddEn</textarea>
                                @Html.ValidationMessageFor(x => x.AddressEn)
                            </div>
                            <div class="tab-pane fade" id="addVi">
                                <textarea class="row-fluid" rows="3" name="AddressVi"> @ViewBag.AddVi</textarea>
                                @Html.ValidationMessageFor(x => x.AddressVi)
                            </div>
                        </div>
                    </div>
                </div>
             @*   <div class="control-group row-fluid">
                        <label class="control-label span3">@Admin.Dis <span class="help-block">@Admin.Dis</span></label>
                        <div class="controls span7">
                            <ul id="tabExample2" class="nav nav-tabs">
                                <li class="active"><a href="#DisEn" data-toggle="tab">@Admin.Vietnamese</a></li>
                                <li><a href="#DisVi" data-toggle="tab">@Admin.English</a></li>
                            </ul>
                            <div class="tab-content">
                                <div class="tab-pane fade in active" id="DisEn">
                                   <input class="span12" type="text" name="DisEn" value="@DetailBag.DisEn)"/>
                                </div>
                                <div class="tab-pane fade" id="DisVi">
                                    <input class="span12" type="text" name="DisVi" value="@DetailBag.DisVi)"/>
                                </div>
                            </div>
                        </div>
                    </div>*@
            </div>
            <div class="modal-footer">
                <input type="button" class="btn" data-dismiss="modal" value="Close" onclick="hide()" />
                <input type="submit" class="btn btn-primary" value="Save changes" />
            </div>
        </div>
    }
</div>
<!-- End .content -->
<a class="btn change_color_outside"><i class="paint_bucket"></i></a>
<script>
    $('.close1').click(function (e) {
        //hủy bỏ các link liên kết,"bỏ dấu #"
        //$("#myModal").addClass("hidden");
        e.preventDefault();
        //đóng thẻ dialog
        $("#dialog").fadeOut(500);
        //đóng thẻ nền dialog
        $("#dialog_nen").fadeOut(500);
    });
</script>
